import { RouteRecordRaw, createRouter, createWebHistory } from "vue-router";

const routes: RouteRecordRaw[] = [
    {
        path: '/demo',
        name: 'Demo',
        component: () => import('@/views/demo/Demo.vue')
    },
    {
        path: '/hook',
        name: 'Hook',
        component: () => import('@/views/demo/Hook.vue')
    },
    {
        path: '/provide',
        name: 'Provide',
        component: () => import('@/views/demo/Provide.vue')
    },
    {
        path: '/vmodel',
        name: 'vmodel',
        component: () => import('@/views/demo/VModel.vue')
    },
    {
        path: '/pinia',
        name: 'Pina',
        component: () => import('@/views/demo/Pina.vue')
    },
    {
        path: '/pinia2',
        name: 'Pina2',
        component: () => import('@/views/demo/Pina2.vue')
    },
    {
        path: '/fileListUpload2',
        name: 'fileListUpload2',
        component: () => import('@/views/demo/FileListUpload2.vue')
    },
    {
        path: '/fileListUpload',
        name: 'fileListUpload',
        component: () => import('@/views/demo/FileListUpload.vue')
    },
    {
        path: '/wangeditor',
        name: 'wangeditor',
        component: () => import('@/views/demo/Editor.vue')
    },
    {
        path: '/login',
        name: 'Login',
        component: () => import('@/views/Login.vue')
    },
    {
        path: "/:pathMatch(.*)*",
        component: () => import("../views/404.vue"),
        meta: { hidden: true },
     },
    {
        path: '/',
        name: 'Layout',
        component: () => import('@/views/layout/Layout.vue'),
        children: [
            {
                path: '/',
                name: 'Home',
                component: () => import('@/views/layout/Home.vue')
            },
            // {
            //     path: '/userinfo',
            //     name: 'UserInfo',
            //     component: () => import('@/views/userinfo/UserInfo.vue')
            // },
            // {
            //     path: '/fee',
            //     name: 'Fee',
            //     component: () => import('@/views/fee/Fee.vue')
            // },
            // {
            //     path: '/administratorrole',
            //     name: 'Administratorrole',
            //     component: () => import('@/views/admin/Administratorrole.vue')
            // },

        ]
    }

]


const router = createRouter(({
    history: createWebHistory(),
    routes
}))

export default router